package net.adetech.crj.bean;

import java.io.Serializable;

public class PaperProgress implements Serializable {
    private String ywbh;
    private String zjzl;
    private String bzjd;
    private String emsdh;
    private String xm;
    private String slrq;
    private String bzjd_text;

    public String getYwbh() {
        return ywbh;
    }

    public void setYwbh(String ywbh) {
        this.ywbh = ywbh;
    }

    public String getZjzl() {
        return zjzl;
    }

    public void setZjzl(String zjzl) {
        this.zjzl = zjzl;
    }

    public String getBzjd() {
        return bzjd;
    }

    public void setBzjd(String bzjd) {
        this.bzjd = bzjd;
    }

    public String getEmsdh() {
        return emsdh;
    }

    public void setEmsdh(String emsdh) {
        this.emsdh = emsdh;
    }

    public String getXm() {
        return xm;
    }

    public void setXm(String xm) {
        this.xm = xm;
    }

    public String getSlrq() {
        return slrq;
    }

    public void setSlrq(String slrq) {
        this.slrq = slrq;
    }

    public String getPaperTypeName() {
        if ("14".equals(this.zjzl)) {
            return "普通护照";
        }
        if ("21".equals(this.zjzl)) {
            return "往来港澳通行证";
        }
        if ("25".equals(this.zjzl)) {
            return "往来台湾通行证";
        }
        return "";
    }

    public String getBzjd_text() {
        return bzjd_text;
    }

    public void setBzjd_text(String bzjd_text) {
        this.bzjd_text = bzjd_text;
    }

    public int getStep() {
        //未受理
        if ("11".equals(this.bzjd) || "10".equals(this.bzjd)) {
            return 0;
        }

        //审核中
        if ("21".equals(this.bzjd)) {
            return 2;
        }

        //制证中
        if ("22".equals(this.bzjd)) {
            return 3;
        }

        //快递寄出
        if ("23".equals(this.bzjd)) {
            return 4;
        }


        if ("24".equals(this.bzjd) || "25".equals(this.bzjd) || "26".equals(this.bzjd)) {
            //快递寄出
            if (this.emsdh != null && !"".equals(this.emsdh)) {
                return 4;
            }
            //办理机关领取
            else {
                return 5;
            }

        }
        return 1;
    }

    public String getSlrqName() {
        if (this.slrq != null && this.slrq.length() == 8) {
            return this.slrq.substring(0, 4) + "年" + Integer.parseInt(this.slrq.substring(4, 6)) + "月" + Integer.parseInt(this.slrq.substring(6, 8)) + "日";
        }
        return this.slrq;
    }

    public boolean getStepGt1() {
        return this.getStep() >= 1;
    }

    public boolean getStepLt1() {
        return this.getStep() < 1;
    }

    public boolean getStepGt2() {
        return this.getStep() >= 2;
    }

    public boolean getStepLt2() {
        return this.getStep() < 2;
    }

    public boolean getStepGt3() {
        return this.getStep() >= 3;
    }

    public boolean getStepLt3() {
        return this.getStep() < 3;
    }

    public boolean getStepGt4() {
        return this.getStep() >= 4;
    }

    public boolean getStepLt4() {
        return this.getStep() < 4;
    }

    public boolean getStepEq4() {
        return this.getStep() == 4;
    }

    public boolean getStepEq5() {
        return this.getStep() == 5;
    }

    public boolean getStepNe4() {
        return this.getStep() != 4;
    }

    public boolean getStepNe5() {
        return this.getStep() != 5;
    }



}
